import styles from './index.module.scss'
const Input = ({ type = 'text', value, name, placeholder,onChange,onExtraClick,extra, ...rest }) => {
    return (
        <div className={styles.root}>
            <input
                value={value}
                className="input"
                type={type}
                name={name}
                placeholder={placeholder}
                onChange={onChange}
                {...rest}
                />
            {extra && <div className="extra" onClick={onExtraClick}>{extra}</div>}
        </div>
    )
}

export default Input